
import java.awt.Color;
import java.awt.GridLayout;

import javax.swing.JPanel;

import Pieces.Board;

public class BoardPanel extends JPanel
{
    BlockPanel[][] bg;

    public BoardPanel()
    {
    	bg = new BlockPanel[Board.BOARD_HEIGHT][Board.BOARD_WIDTH];
    	setLayout(new GridLayout(Board.BOARD_HEIGHT, Board.BOARD_WIDTH));
    	for(int i = 0; i < Board.BOARD_HEIGHT; i++){
			for(int j = 0; j < Board.BOARD_WIDTH; j++){
				bg[i][j]= new BlockPanel();
				add(bg[i][j]);
			}
		}
		
	
        setBackground(Color.WHITE);
        //initialize blob and all blocks in it
        //set layout to probably GridLayout
        //add all BlockPanels in blob
    }
    
    public void changeColor(int i, int j, Color c){
    	bg[i][j].changeColor(c);
    }
    
}
